﻿using pcEntity;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;

namespace pcObjectLibrary
{
    //public class UserObjLibrary
    //{
    //    public string ipAddress { get; set; }
    //    public string macAddress { get; set; }
    //    public Name Name { get; set; }
    //    public Address address { get; set; }
    //    public Communication communication { get; set; }

    //}
    //public class Name
    //{
    //    public string First { get; set; }
    //    public string Middle { get; set; }
    //    public string Last { get; set; }
    //}
    //public class Communication
    //{
    //    public string email { get; set; }
    //    public string telephone { get; set; }
    //}
    //public class Address
    //{
    //    public string address1 { get; set; }
    //    public string address2 { get; set; }
    //    public string city { get; set; }
    //    public string state { get; set; }
    //    public string zip { get; set; }
    //}

    public class UserObjLibrary : tUser
    {
        [ScaffoldColumn(false)]
        public new int userId { get; set; }
        [ScaffoldColumn(false)]
        public new System.Guid globalId { get; set; }
        [Display(Name = "First Name")]
        [Required]
        public new string firstName { get; set; }
        [Display(Name = "Last Name")]
        [Required]
        public new string lastName { get; set; }
        [Display(Name = "Email")]
        [Required]
        public new string email { get; set; }
        [Display(Name = "Telephone")] [DataType(DataType.PhoneNumber)]
        public new string telephone { get; set; }
        [Display(Name = "Middle Name")]
        public new string middleName { get; set; }
        [Display(Name = "User Name")]
        [Required]
        public new string userName { get; set; }

         [ScaffoldColumn(false)]
        public new Nullable<System.DateTime> passwordLastChanged { get; set; }
         [ScaffoldColumn(false)]
        public new bool passwordDisabled { get; set; }
         [ScaffoldColumn(false)]
        public new bool isActive { get; set; }
         [ScaffoldColumn(false)]
        public new bool isDeleted { get; set; }
         [ScaffoldColumn(false)]
        public new Nullable<int> isAdmin { get; set; }
         [ScaffoldColumn(false)]
        public new System.DateTimeOffset dateCreated_utc { get; set; }
         [ScaffoldColumn(false)]
        public new System.DateTimeOffset lastUpdated_utc { get; set; }
         [ScaffoldColumn(false)]
        public new System.DateTimeOffset lastActivityDate_utc { get; set; }
         [ScaffoldColumn(false)]
        public new string userRegistered_ip { get; set; }
         [ScaffoldColumn(false)]
        public new string lastActivity_ip { get; set; }
         [ScaffoldColumn(false)]
        public new string registered_MAC_address { get; set; }
         [ScaffoldColumn(false)]
        public new string lastActive_MAC_address { get; set; }

        [Display(Name="Account Type")]
         public new int userTypeId { get; set; }

         [Display(Name = "Password")]
         [Required]
         public string password { get; set; }

        [Display(Name="Registration Code"),Required]
         public string registrationCode { get; set; }

        [Display(Name = "Timezone")]
        [Required(ErrorMessage="Please select your timezone")]
        public new string registeredTimeZone { get; set; }

        public IEnumerable<SelectListItem> timezonesList { get; set; }

        public PunchObjectLibrary lastPunch { get; set; }
    }
}
